/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package copecscheduling;

import java.util.ArrayList;
import java.util.Calendar;
import java.util.Random;


/**
 *
 * @author nacho
 */
public class Bombero {



    private ArrayList<Integer> monthPlanification = new ArrayList<Integer>();
    private ArrayList<Integer> history = new ArrayList<Integer>();
    private float fitness = 0;


    public Bombero(){

    }

    public void init(int NDAYS, int HSTDAYS,Calendar date){
        monthPlanification = new ArrayList<Integer>();
        for(int i=0;i<NDAYS;i++){
            monthPlanification.add(0);
        }
    }
    
    public void setFitness(float fitness){
       this.fitness = fitness;
    }

    public float getFitness(){
        return this.fitness;
    }
     
    public ArrayList<Integer> getPlanification(){

        return this.monthPlanification;
    }
     
    public void setPlanification(ArrayList<Integer> planification){
        int i;

        for(i=0;i<planification.size();i++)
            this.monthPlanification.set(i,planification.get(i));
    }

    public ArrayList<Integer> getHistory() {
        return history;
    }

    public void setHistory(ArrayList<Integer> history) {
        int i;

        for(i=0;i<history.size();i++)
            this.history.set(i, history.get(i));
    }

    public String getStringPlanification(){
        int i;
        String tmp="";

        for(i=0;i<this.history.size();i++){
            tmp = tmp + this.history.get(i);
        }
        for(i=0;i<this.monthPlanification.size();i++){
            tmp = tmp + this.monthPlanification.get(i);
        }
        return tmp;
    }


}
